﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<System.Collections.Generic.IList<SmartCollector.WebUI.Models.tbl_Item>>" %>
<%{
      int row = 0;
      foreach (var item in Model)
      {%>
<% if (row % 2 == 0)
   {
%>
<div class="article_row cols2 clearfix">
    <div class="article_column column1">
        <%}
   else
   {%>
        <div class="article_column column2">
            <%} %>
            <div class="contentpaneopen">
                <h2 class="contentheading">
                    <a href="/Item/Details/<%=item.Id%>" class="contentpagetitle">
                        <%=item.Title %></a></h2>
                <div class="article-tools clearfix">
                    <div class="article-meta" style="width: 100%;">
                        <span class="createdate">
                            <%=Convert.ToDateTime(item.Date).ToString() %></span><span class="createby">
                                <%=item.tbl_ReferenceSite.SiteName %></span>
                    </div>
                </div>
                <div class="article-content">
                    <%if (!string.IsNullOrEmpty(item.ImageUrl.Trim()))
                      {%>
                    <div class="img_caption left">
                        <a href="/Item/Details/<%=item.Id %>" class="contentpagetitle">
                            <img src="<%=item.ImageUrl %>" alt="<%=item.Title %>" style="width: 130px;max-height:120px; " class="caption" align="left" />
                        </a>
                    </div>
                    <%} %>
                    <p>
                        <%=SmartCollector.WebUI.Helpers.Heppers.CropString(item.Description,200) %>
                        <a href="/Item/Details/<%=item.Id%>" class="Read more..." style="font-size: 92%;">Chi
                            Tiết »</a>
                    </p>
                    <%--  <span class="containerCountComment"><a target="" href="http://">Comments (1)</a>
                </span>--%>
                </div>
            </div>
        </div>
        <% row++; %>
        <%if (row % 2 == 0)
          {%>
    </div>
    <%} %>
    <%}
      if (row % 2 == 1)
      {
    %>
    </div>
    <%
      }
  } %>
    <%-- <div class="article_column column2">
        <div class="contentpaneopen">
            <h2 class="contentheading">
                <a href="/Item/Details/<%=item.ID %>" class="contentpagetitle"><%=item.Title %></a></h2>
            <div class="article-tools clearfix">
                <div class="article-meta" style="width: 100%;">
                     <span class="createdate"><%=Convert.ToDateTime(item.Date).ToString() %></span><span class="createby">
                        <%=item.ReferenceSite %></span>
                </div>
            </div>
            <div class="article-content">
                <div style="float: left;" class="img_caption left">
                <a href="/Item/Details/<%=item.ID %>" class="contentpagetitle">
                    <img src="<%=item.ImageUrl %>" alt="Hình mẫu" title="Hình mẫu" class="caption"
                        align="left" /></a>
                    </div>
                <p>
                    <%=item.Description %>
                </p>
                <span class="containerCountComment"><a target="" href="http://">Comments (5)</a>
                </span>
            </div>
        </div>
    </div>
</div>--%>
